#ifndef MACHINE_SETTING_H
#define MACHINE_SETTING_H

#include <QSettings>
#include <QtCore>

#include "setting_normal.h"
#include "setting_text.h"
#include "setting_barcode.h"
#include "setting_qrcode.h"


//机器设置，主要涉及到机器型号，打印标签纸大小等等信息。
class MACHINE_SETTING
{
public:
    MACHINE_SETTING();

    void save_setting();    //加载配置
    void read_setting();    //保存配置
    void init_setting();    //初始化配置

    setting_normal& get_NORMAL();//获得NORMAL设置
    setting_barcode& get_BARCODE();//获得BARCODE设置
    setting_qrcode& get_QRCODE();//获得QRCODE设置
    setting_text& get_TEXT();//获得TEXT设置

private:
    QSettings* setting;

    setting_normal NORMAL;
    setting_text TEXT;
    setting_barcode BARCODE;
    setting_qrcode QRCODE;
};

#endif // MACHINE_SETTING_H
